<?php
namespace Admin\Controller;
use Think\Controller;
class WriteController extends BaseController {
	public function index () {
		$this->display();
	}

	public function add () {
		$article = M('article');
		$a['article_type'] = I('post.article_type');
		$a['article_content'] = $_POST['article_content'];
		$time = time();
		$a['newstime'] = $time;

		
		$article->add($a);

		
		$this->redirect('/admin/article');
		
			
	
		

	}

	
}